package com.xhsj.user.hr.system.entity;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.google.common.collect.Lists;
import com.xhsj.user.hr.base.BaseEntity;
import com.baomidou.mybatisplus.annotation.Version;

import java.time.LocalDate;
import java.time.LocalDateTime;
import java.util.Date;
import java.util.List;

import com.baomidou.mybatisplus.annotation.*;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

/**
 * <p>
 * 需求申请表
 * </p>
 *
 * @author suxiaolin
 * @since 2020-11-11
 */
@Data
@EqualsAndHashCode(callSuper = true)
@Accessors(chain = true)
@TableName("tb_hr_demand_apply")
public class TbHrDemandApply extends BaseEntity<TbHrDemandApply> {

    private static final long serialVersionUID = 1L;

    /**
     * 部门id
     */
    @TableField("dept_id")
    private Long deptId;

    /**
     * 部门负责人id
     */
    @TableField("dept_manager_id")
    private Long deptManagerId;

    /**
     * 需求名称
     */
    @TableField("demand_name")
    private String demandName;

    /**
     * 所属模块
     */
    @TableField("module")
    private String module;

    /**
     * 计划时间
     */
    @TableField("plan_time")
    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd")
    private Date planTime;

    /**
     * 节点id
     */
    @TableField("node_id")
    private Long nodeId;

    /**
     * 节点名称
     */
    @TableField("node_name")
    private String nodeName;

    /**
     * 创建人名称
     */
    @TableField("create_name")
    private String createName;

    /**
     * 部门名称
     */
    @TableField("dept_name")
    private String deptName;

    /**
     * 流程id 外键  tb_global_business id
     */
    @TableField("business_id")
    private Long businessId;


    /**
     * 提交状态 1 保存 2 提交
     */
    @TableField("submit_status")
    private Integer submitStatus;

    @TableField(exist = false)
    private Long processTaskId;

    @TableField(exist = false)
    private List<TbHrDemandApplyDetail> applyDetailList = Lists.newArrayList();


}
